package com.smart4j.framework.aop.spring.introduction;

import org.aopalliance.intercept.MethodInvocation;
import org.springframework.aop.support.DelegatingIntroductionInterceptor;
import org.springframework.stereotype.Component;

/**
 * description: SpringAOP introduction 引入增强 
 * @version v1.0
 * @author w
 * @date 2018年9月23日下午10:07:59
 */
@Component
public class GreetingIntroductionAdvice extends DelegatingIntroductionInterceptor implements Apology {

	private static final long serialVersionUID = 1L;
	
	@Override
	public Object invoke(MethodInvocation mi) throws Throwable {
		return super.invoke(mi);
	}
	
	@Override
	public void saySorry(String name) {
		System.out.println(" sorry ..."+name +" please forgive me!");
	}

}
